import 'package:oramemo/generated/json/base/json_convert_content.dart';
import 'package:oramemo/model/inline_object.dart';

InlineObject $InlineObjectFromJson(Map<String, dynamic> json) {
  final InlineObject inlineObject = InlineObject();
  final String? deviceModel = jsonConvert.convert<String>(json['deviceModel']);
  if (deviceModel != null) {
    inlineObject.deviceModel = deviceModel;
  }
  final String? customModelId = jsonConvert.convert<String>(
      json['customModelId']);
  if (customModelId != null) {
    inlineObject.customModelId = customModelId;
  }
  return inlineObject;
}

Map<String, dynamic> $InlineObjectToJson(InlineObject entity) {
  final Map<String, dynamic> data = <String, dynamic>{};
  data['deviceModel'] = entity.deviceModel;
  data['customModelId'] = entity.customModelId;
  return data;
}

extension InlineObjectExtension on InlineObject {
  InlineObject copyWith({
    String? deviceModel,
    String? customModelId,
  }) {
    return InlineObject()
      ..deviceModel = deviceModel ?? this.deviceModel
      ..customModelId = customModelId ?? this.customModelId;
  }
}